package cn.cvs.service.storageRecord;

import cn.cvs.pojo.StorageRecord;

import java.util.List;


public interface StroageRecordService {
    /**
     * 分页查询
     *
     * @param queryGoodsName
     * @param querySupplierId
     * @param queryPayStatus
     * @param pageIndex
     * @param pageSize
     * @return
     * @throws Exception
     */
    List<StorageRecord> findStorageList(String queryGoodsName, Integer querySupplierId
            , Integer queryPayStatus, Integer pageIndex, Integer pageSize) throws Exception;

    /**
     * 查询所有入库记录
     *
     * @param queryGoodsName
     * @param querySupplierId
     * @param querypayStatus
     * @return
     * @throws Exception
     */
    int findCount(String queryGoodsName, Integer querySupplierId, Integer querypayStatus) throws Exception;

    /**
     * 新增入库记录
     *
     * @param storageRecord
     * @return
     * @throws Exception
     */
    boolean addStorageRecord(StorageRecord storageRecord) throws Exception;

    /**
     * 修改入库记录
     *
     * @param storageRecord
     * @return
     * @throws Exception
     */
    boolean updateStorageRecord(StorageRecord storageRecord) throws Exception;

    /**
     * 查看入库记录
     *
     * @param id
     * @return
     * @throws Exception
     */
    StorageRecord findStorageRecordById(Integer id) throws Exception;

    /**
     * 删除入库信息
     *
     * @param id
     * @return
     * @throws Exception
     */
    boolean deleteStorageRecordById(Integer id) throws Exception;

    /**
     * 获取供应商写的入库数量
     *
     * @param id
     * @return
     * @throws Exception
     */
    List findStorageRecordBySupplierId(Integer id) throws Exception;
}
